package com.mao.constructor;

public class Student {
    String name;
    int age;
    char sex;
    // 构造器，无参构造器
    public Student(){
        System.out.println("======执行无参构造器=======");
    }
    // 含参构造器
    public Student(String s){
        System.out.println("======执行含参构造器=======");
    }
    public Student(String name,char sex,int age){
        System.out.println("======执行含参构造器=======");
        this.name = name;
        this.sex = sex;
        this.age = age;
    }
}
